package com.stu.student_back_end.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.stu.student_back_end.entity.TblMoveAndOut;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

/**
 * 迁入迁出记录mapper层接口
 */

@Mapper
public interface TblMoveAndOutMapper extends BaseMapper<TblMoveAndOut> {

    //查询五天内的记录数
    @Select("select count(*) from tbl_moveandout where createTime between date_sub(now(),interval 15 day) and curdate()")
    int queryMoveAndOutCount();
}
